//
//  FQDSubscribeManager.h
//  FakeQDaily
//
//  Created by mewxiv on 9/22/16.
//  Copyright © 2016 Xensius. All rights reserved.
//

#import <Foundation/Foundation.h>
@class FQDColumn;

@interface FQDSubscribeManager : NSObject

// 所有订阅的栏目
@property (nonatomic, readonly, strong) NSArray *allColumns;

+ (instancetype)sharedManager;
// 请求当前所有订阅的栏目
- (void)getAllSubscribeColumns:(NSString *)userId completion:(void (^)(BOOL success))completion;
// 订阅栏目
- (void)addSubscribeColumn:(NSString *)columnId completion:(void (^)(BOOL success))completion;
// 取消订阅栏目
- (void)removeSubscribeColumn:(NSString *)columnId completion:(void (^)(BOOL success))completion;
// 订阅或取消订阅栏目，如果当前没有登录会提示用户先登录，再执行操作
- (void)toggleSubscribeColumn:(NSString *)columnId completion:(void (^)(BOOL success, BOOL subscribed))completion;
// 根据栏目id获取对应栏目数据
- (FQDColumn *)columnForColumnId:(NSString *)columnId;
// 判断是否订阅该栏目
- (BOOL)hasSubscribedColumn:(NSString *)columnId;
// 判断是否订阅过任何栏目
- (BOOL)hasSubscribedAnyColumn;

@end
